Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using utils.showAlert for Local DNS and Local CNAME pages. #2203

Merged
merged 5 commits into from
May 19, 2022

Conversation

rdwebdesign
Copy link
Member

By submitting this pull request, I confirm the following:

  • I have read and understood the contributors guide, as well as this entire template.
  • I have made only one major change in my proposed changes.
  • I have commented my proposed changes within the code.
  • I have tested my proposed changes.
  • I am willing to help maintain this change if there are issues with it later.
  • I give this submission freely and claim no ownership.
  • It is compatible with the EUPL 1.2 license
  • I have squashed any insignificant commits. (git rebase)
  • I have Signed Off all commits. (git commit --signoff)

What does this PR aim to accomplish?:

Fix #1357.

How does this PR accomplish the above?:

Replacing individual local functions with the global utils.showAlert function.

What documentation changes (if any) are needed to support this PR?:

none.

Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
@rdwebdesign rdwebdesign requested a review from yubiuser May 16, 2022 04:57
Copy link
Member

@yubiuser yubiuser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tried it but I never get the success message (but action is performed successfully).

Additionally, (even if not the main concern of this PR) it would be nice if the input fields were cleaned after action was performed.

@yubiuser yubiuser linked an issue May 16, 2022 that may be closed by this pull request
Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
@rdwebdesign rdwebdesign requested a review from yubiuser May 17, 2022 18:56
Copy link
Member

@yubiuser yubiuser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if the fields should be cleaned after something is deleted. A use case would be adding in data already, but spotting something to delete first, which would trigger the cleaning

scripts/pi-hole/js/customdns.js Outdated Show resolved Hide resolved
Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
@rdwebdesign rdwebdesign requested a review from yubiuser May 17, 2022 19:35
@yubiuser
Copy link
Member

The missing success message was due to a FTL resolver startup delay configured by DELAY_STARTUP=5. After removing the delay the success message appeared as expected.
This behavior gave the idea to pi-hole/FTL#1349

@yubiuser yubiuser merged commit 9a8f5cb into devel May 19, 2022
@yubiuser yubiuser deleted the fix/issue1357 branch May 19, 2022 18:18
@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/pi-hole-ftl-v5-16-web-v5-13-and-core-v5-11-1-released/56384/1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

customdns.js: use utils.showAlert()
3 participants